package com.example;

import android.app.Activity;
import android.app.AlertDialog;
import android.content.DialogInterface;
import android.os.Bundle;

/**
 * BRAIN-STORE PROJECT.
 * <p/>
 * User: Sasha
 * Date: 24.03.12
 * Time: 22:53
 */
public class MyActivity extends Activity {
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        openNewsDialog("AndroidModule");
    }

    private void openNewsDialog(String title) {
        AlertDialog.Builder builder = new AlertDialog.Builder(this);
        builder.setTitle(title);
        builder.setPositiveButton("OK", new DialogInterface.OnClickListener() {
            public void onClick(DialogInterface dialog, int which) {
                openNewsDialog("Which = " + which + ", dialog = " + dialog);
            }
        });
        builder.show();
    }
}